﻿{{ var groups = it.groups, selectedGroups = it.selectedGroups; }}
{{~ groups :group }}
    {{#def.buildListItem:group }}
{{~ }}
{{? groups.length === 0 }}
    <li class="pTop5 pBottom5 TxtCenter">{{=_l('没有符合条件的群组')}}</li>
{{?}}

{{##def.buildListItem:item:
<li class="singleGroup">
    <label class="Hand Block">
        {{ var isChecked = selectedGroups.indexOf(item.groupId) > -1; }}
        <input type="checkbox" data-groupid="{{= item.groupId }}" {{= isChecked ? 'checked' : ''  }}>
        {{? item.avatar }}
        <span class="groupAvatar circle">
            <img src="{{= item.avatar }}" class="w100 h100">
        </span>
        {{?}}
        <span class="groupName" title='{{! item.name }}'>
            {{! item.name }}
        </span>
    </label>
</li>
#}}
